You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A navigable is script-closable if its active browsing context is an auxiliary browsing context that was created by a script (as opposed to by an action of the user), or if it is a top-level traversable whose session history entries's size is 1.
According to whatwg/html#1866, browsers don't track whether a browsing context is created by script. Rather, they allow windows created by window.open, link navigation, or form submission to be script-closable.
I'm working on updating the spec to reflect this through a is opened by web content flag.
Afaik, WPT isn't able to create a window that is not created by web content. WebDriver specifies https://w3c.github.io/webdriver/#new-window that could be suitable. But given it invokes the window-open-steps, it would likely have to clear this is opened by web content flag.
I imagine a test should open a new window that has is opened by web content set to false. Then navigate it a few times such that the session history length is larger than one, and assert it cannot be closed from script. To still close the window anyway, testdriver would also have to implement https://w3c.github.io/webdriver/#close-window.
The text was updated successfully, but these errors were encountered:
https://html.spec.whatwg.org/#script-closable
According to whatwg/html#1866, browsers don't track whether a browsing context is created by script. Rather, they allow windows created by
window.open
, link navigation, or form submission to be script-closable.I'm working on updating the spec to reflect this through a
is opened by web content
flag.Afaik, WPT isn't able to create a window that is not created by web content. WebDriver specifies https://w3c.github.io/webdriver/#new-window that could be suitable. But given it invokes the window-open-steps, it would likely have to clear this
is opened by web content
flag.I imagine a test should open a new window that has
is opened by web content
set to false. Then navigate it a few times such that the session history length is larger than one, and assert it cannot be closed from script. To still close the window anyway, testdriver would also have to implement https://w3c.github.io/webdriver/#close-window.The text was updated successfully, but these errors were encountered: